package com.wxzz.elearing.comment.api.admin;

import com.alibaba.fastjson.JSONObject;
import com.wxzz.elearing.comment.dto.AnswersDescDto;
import com.wxzz.elearing.comment.dto.AnswersDto;
import com.wxzz.elearing.comment.dto.CommunityQuestionsAnswersDto;
import com.wxzz.elearing.comment.dto.QuestionsAnswersDto;
import com.wxzz.elearing.comment.entity.Comment;
import com.wxzz.elearing.comment.entity.CommunityComment;
import com.wxzz.elearing.comment.entity.QuestionsAnswersList;
import com.wxzz.elearing.comment.service.ICommentService;
import com.wxzz.elearing.comment.service.ICommunityCommentService;
import com.wxzz.elearing.comment.vo.AnswersVo;
import com.wxzz.elearing.comment.vo.QuestionsContentDescVo;
import com.wxzz.elearning.common.vo.JgPageVo;
import com.wxzz.elearning.common.vo.ReturnVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@RestController
@RequestMapping("/admin-comment-controller")
@Api(tags = "问答评论接口(平台)")
public class AdminCommentController {

    @Autowired
    private ICommentService iCommentService;


    @ApiOperation(value = "平台问答评论删除(平台)", notes = "平台问答评论删除(平台)", httpMethod = "POST", tags = "平台")
    @RequestMapping(value = "deleteComment", method = RequestMethod.POST)
    public ReturnVO deleteComment(@RequestBody Comment comment) {
        return iCommentService.deleteComment(comment);
    }

    @ApiOperation(value = "平台问答文章删除(平台)", notes = "平台问答文章删除(平台)", httpMethod = "POST", tags = "平台")
    @RequestMapping(value = "deleteQueAns", method = RequestMethod.POST)
    public ReturnVO deleteQueAns(@RequestBody QuestionsAnswersList questionsAnswersList) {
        return iCommentService.deleteQueAns(questionsAnswersList);
    }
}
